
import request from '../../utils/request';
//data：post请求中携带的数据（obj格式），params：get请求中携带的数据（就是在浏览器地址xx/xx/xx后面?XX=oo&XX=oo这部分数据，obj格式）
//管理员登陆
export default{
/*-------------------------------------------------------------角色相关-------------*/ 
    
    /*-------------部门相关-------------*/ 
    //部门列表
    deptTreeList: query => {
        return request({
            url: '/pet-admin/system/dept/list',
            method: 'post',
            data: query
        });
    },
    //部门详情
    deptInfo: query => {
        return request({
            url: '/pet-admin/system/dept/detail',
            method: 'post',
            data: query
        });
    },
    
    //添加部门
    addDept: query => {
        return request({
            url: '/pet-admin/system/dept/add',
            method: 'post',
            data: query
        });
    },
    
    //更新部门
    updateDept: query => {
        return request({
            url: '/pet-admin/system/dept/edit',
            method: 'post',
            data: query
        });
    },
    
    //删除部门
    deleteDept: query => {
        return request({
            url: '/pet-admin/system/dept/delete',
            method: 'post',
            data: query
        });
    },
    // 部门树
    deptTreeselect: query => {
        return request({
            url: '/pet-admin/system/dept/treeList',
            method: 'post',
            data: query
        });
    },
    
}
